from LA.vector import Vector

if __name__ == "__main__":
    vec = Vector([1, 4])
    print(vec)

    vec2 = Vector([4, 7])
    print("{}+{}={}".format(vec, vec2, vec+vec2))
    print("{}*{}={}".format(2, vec2, 2*vec2))

    zero = Vector.zero(3)
    print(zero)

    print("norm",vec.norm())
    print("normalize",vec.normalize())

    try:
        zero.normalize()
    except ZeroDivisionError:
        print("zero is error")